home *** CD-ROM | disk | FTP | other *** search
/ 3DFX Velocity 100 / 3DFX Velocity 100.iso / Drivers / nt351 / Oemsetnt.inf < prev    next >
Encoding:
INI File  |  1999-06-15  |  16.4 KB  |  571 lines

  1.  
  2. [Identification]
  3.     OptionType = VIDEO
  4.  
  5. [LanguagesSupported]
  6.     ENG
  7.  
  8.  
  9. ; Option list order: Option = Miniport driver, BitsPerPel, XResolution, YResolution, VRefresh, Interlaced
  10. ; If you don't want to create a VRefresh or Interlaced value under the service
  11. ; parameters then use the value ""
  12.  
  13.  
  14. [Options]
  15.     "3Dfx Velocity 100/200"  = velocity, 16, 640, 480, 60, 0
  16.  
  17.  
  18. ; This maps detected options into the options we support
  19. ; Format: DetectedOption = MappedOption
  20.  
  21. [MapOfOptions]
  22.     "VGA"                       = "VGA"
  23.     "COMPAQ AVGA"               = "VGA"
  24.     "COMPAQ AGB"                = "VGA"
  25.     "8514 MONITOR UNKNOWN"      = "VGA"
  26.     "8514 VGA MONITOR"          = "VGA"
  27.     "8514 8503 MONO"            = "VGA"
  28.     "8514 8514 GAD"             = "VGA"
  29.     "GENOA VGA"                 = "VGA"
  30.     "VIDEO7 VGA DRAM"           = "VIDEO7 VGA VRAM 640x480x4"
  31.     "VIDEO7 VGA VRAM"           = "VIDEO7 VGA VRAM 640x480x4"
  32.     "TRIDENT VGA"               = "VGA"
  33.     "TRIDENT VGA 9100"          = "VGA"
  34.     "PARADISE VGA"              = "VGA"
  35.     "PARADISE VGA PROM"         = "VGA"
  36.     "PARADISE VGA CHIP 1F"      = "VGA"
  37.     "ATI VGA"                   = "VGA"
  38.     "ATI VGA WONDDER3"          = "VGA"
  39.     "TSENGLAB VGA ET3000"       = "VGA"
  40.     "TSENGLAB VGA ET4000"       = "TSENGLAB VGA ET4000 640x480x4x60"
  41.     "CIRRUS VGA"                = "VGA"
  42.     "CIRRUS VGA 610-620 REVC"   = "VGA"
  43.     "XGA"                       = "XGA 640x480x8"
  44.     "DELL DGX"                  = "DELL DGX 640x480x8"
  45.     "S3 VGA"                    = "S3 VGA 640x480x8"
  46.     "MEDIA VISION VGA"          = "MEDIA VISION VGA 640x480x8"
  47.     "PRODESIGNER II"            = "TSENGLAB VGA ET4000 640x480x4x60"
  48.  
  49.  
  50.  
  51. ; Order of the information:
  52. ; Port driver = Type, Group, ErrorControl, Tag, InstalledDisplay, VgaCompatible( 0/1 ), EventMessageFile, TypesSupported
  53.  
  54.  
  55. [MiniportDrivers]
  56.     velocity = !SERVICE_KERNEL_DRIVER, Video, !SERVICE_ERROR_NORMAL, 11, {framebuf}, 0 , %SystemRoot%\System32\IoLogMsg.dll , 7
  57.  
  58.  
  59.  
  60.  
  61. ;-----------------------------------------------------------------------
  62. ; OPTION TEXT SECTION
  63. ; -------------------
  64. ; These are text strings used to identify the option to the user.
  65. ; This string on the right side will appear in the "Select Device" list while
  66. ; installing the drivers.
  67. ;-----------------------------------------------------------------------
  68.  
  69. [OptionsTextENG]
  70.     "3Dfx Velocity 100/200" = "3Dfx Velocity 100/200"
  71.  
  72.  
  73. ;---------------------------------------------------------------------------
  74. ; 1. Identify
  75. ;
  76. ; DESCRIPTION:   To verify that this INF deals with the same type of options
  77. ;                as we are choosing currently.
  78. ;
  79. ; INPUT:         None
  80. ;
  81. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL
  82. ;                $($R1): Option Type (COMPUTER ...)
  83. ;                $($R2): Diskette description
  84. ;---------------------------------------------------------------------------
  85.  
  86. [Identify]
  87.     ;
  88.     ;
  89.     read-syms Identification
  90.  
  91.     set Status     = STATUS_SUCCESSFUL
  92.     set Identifier = $(OptionType)
  93.     set Media      = #("Source Media Descriptions", 1, 1)
  94.  
  95.     Return $(Status) $(Identifier) $(Media)
  96.  
  97.  
  98.  
  99. ;------------------------------------------------------------------------
  100. ; 2. ReturnOptions:
  101. ;
  102. ; DESCRIPTION:   To return the option list supported by this INF and the
  103. ;                localised text list representing the options.
  104. ;
  105. ;
  106. ; INPUT:         $($0):  Language used. ( ENG | FRN | ... )
  107. ;
  108. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL |
  109. ;                                STATUS_NOLANGUAGE
  110. ;                                STATUS_FAILED
  111. ;
  112. ;                $($R1): Option List
  113. ;                $($R2): Option Text List
  114. ;------------------------------------------------------------------------
  115.  
  116. [ReturnOptions]
  117.     ;
  118.     ;
  119.     set Status        = STATUS_FAILED
  120.     set OptionList     = {}
  121.     set OptionTextList = {}
  122.  
  123.     ;
  124.     ; Check if the language requested is supported
  125.     ;
  126.     set LanguageList = ^(LanguagesSupported, 1)
  127.     Ifcontains(i) $($0) in $(LanguageList)
  128.     goto returnoptions
  129.     else
  130.     set Status = STATUS_NOLANGUAGE
  131.     goto finish_ReturnOptions
  132.     endif
  133.  
  134.     ;
  135.     ; form a list of all the options and another of the text representing
  136.     ;
  137.  
  138. returnoptions = +
  139.     set OptionList     = ^(Options, 0)
  140.     set OptionTextList = ^(OptionsText$($0), 1)
  141.     set Status         = STATUS_SUCCESSFUL
  142.  
  143. finish_ReturnOptions = +
  144.     Return $(Status) $(OptionList) $(OptionTextList)
  145.  
  146.  
  147.  
  148. ;---------------------------------------------------------------------------
  149. ; MapToSupportedOption
  150. ;
  151. ; DESCRIPTION:   To map a hardware detected option to the NT Supported
  152. ;                option which represents it.
  153. ;
  154. ; INPUT:         $($0): Option
  155. ;
  156. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL
  157. ;                $($R1): Mapped Option
  158. ;
  159. ;---------------------------------------------------------------------------
  160.  
  161. [MapToSupportedOption]
  162.     ;
  163.     set Status = STATUS_FAILED
  164.     set MappedOption = $($0)
  165.  
  166.     ;
  167.     ; If the option is one we can support using one of our standard options
  168.     ; then map it to the standard option else map it to the default option
  169.     ; which is VGA.
  170.     ;
  171.  
  172.     set OptionList = ^(MapOfOptions, 0)
  173.     ifcontains $($0) in $(OptionList)
  174.     Debug-Output "We are setting the option list here."
  175.     set MappedOption = #(MapOfOptions, $($0), 1)
  176.     else
  177.     set MappedOption = "VGA"
  178.     endif
  179.  
  180.     set Status = STATUS_SUCCESSFUL
  181.     Return $(Status) $(MappedOption)
  182.  
  183.  
  184.  
  185. [ServicesEntry]
  186.     CurrentEntry = "" ? $(!LIBHANDLE) GetDevicemapValue Video \Device\Video0
  187.  
  188.  
  189. ;
  190. ; InstallOption:
  191. ;
  192. ; FUNCTION:  To copy files representing Options
  193. ;            To configure the installed option
  194. ;            To update the registry for the installed option
  195. ;
  196. ; INPUT:     $($0):  Language to use
  197. ;            $($1):  OptionID to install
  198. ;            $($2):  SourceDirectory
  199. ;            $($3):  AddCopy  (YES | NO)
  200. ;            $($4):  DoCopy   (YES | NO)
  201. ;            $($5):  DoConfig (YES | NO)
  202. ;
  203. ; OUTPUT:    $($R0): STATUS: STATUS_SUCCESSFUL |
  204. ;                            STATUS_NOLANGUAGE |
  205. ;                            STATUS_USERCANCEL |
  206. ;                            STATUS_FAILED
  207. ;
  208.  
  209. [InstallOption]
  210.  
  211.     Debug-Output "We are entering Install Option."
  212.  
  213.     ;
  214.     ; Set default values for
  215.     ;
  216.     set Status       = STATUS_FAILED
  217.     set DrivesToFree = {}
  218.  
  219.     ;
  220.     ; extract parameters
  221.     ;
  222.     set Option   = $($1)
  223.     set SrcDir   = $($2)
  224.     set AddCopy  = $($3)
  225.     set DoCopy   = $($4)
  226.     set DoConfig = $($5)
  227.  
  228.     ;
  229.     ; Check if the language requested is supported
  230.     ;
  231.     set LanguageList = ^(LanguagesSupported, 1)
  232.     Ifcontains(i) $($0) in $(LanguageList)
  233.     else
  234.     set Status = STATUS_NOLANGUAGE
  235.     goto finish_InstallOption
  236.     endif
  237.     read-syms Strings$($0)
  238.  
  239.     ;
  240.     ; check to see if Option is supported.
  241.     ;
  242.  
  243.     set OptionList = ^(Options, 0)
  244.     ifcontains $(Option) in $(OptionList)
  245.     else
  246.     goto finish_InstallOption
  247.     endif
  248.     set OptionList = ""
  249.  
  250.     ;
  251.     ; Option has been defined already
  252.     ;
  253.     set MiniportDriver    = #(Options, $(Option), 1)
  254.     set BitsPerPel        = #(Options, $(Option), 2)
  255.     set XResolution       = #(Options, $(Option), 3)
  256.     set YResolution       = #(Options, $(Option), 4)
  257.     set VRefresh          = #(Options, $(Option), 5)
  258.     set Interlaced        = #(Options, $(Option), 6)
  259.  
  260.     set Type              = $(#(MiniportDrivers, $(MiniportDriver), 1))
  261.     set Group             =   #(MiniportDrivers, $(MiniportDriver), 2)
  262.     set ErrorControl      = $(#(MiniportDrivers, $(MiniportDriver), 3))
  263.     set Tag               =   #(MiniportDrivers, $(MiniportDriver), 4)
  264.     set InstalledDisplays =   #(MiniportDrivers, $(MiniportDriver), 5)
  265.     set VgaCompatible     =   #(MiniportDrivers, $(MiniportDriver), 6)
  266.     set EventMessageFile  =   #(MiniportDrivers, $(MiniportDriver), 7)
  267.     set TypesSupported    =   #(MiniportDrivers, $(MiniportDriver), 8)
  268.  
  269.     read-syms ServicesEntry
  270.     detect    ServicesEntry
  271.  
  272. installtheoption = +
  273.  
  274.     ;
  275.     ; Code to add files to copy list
  276.     ;
  277.  
  278.     ifstr(i) $(AddCopy) == "YES"
  279.     set DoActualCopy = NO
  280.     set FileToCheck = #(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  281.     LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\drivers\"$(FileToCheck)
  282.     ifstr(i) $(STATUS) == NO
  283.         set DoActualCopy = YES
  284.         goto addfiles
  285.     endif
  286.     ForListDo $(InstalledDisplays)
  287.         set FileToCheck = #(Files-DisplayDLLs, $($), 3)
  288.         LibraryProcedure STATUS,$(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\"$(FileToCheck)
  289.         ifstr(i) $(STATUS) == NO
  290.         set DoActualCopy = YES
  291.         endif
  292.     EndForListDo
  293.  
  294. addfiles = +
  295.     ifstr(i) $(DoActualCopy) == NO
  296.         shell "subroutn.inf" DriversExist $($0) $(String1)
  297.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  298.         Debug-Output "VIDEO.INF: shelling DriversExist failed"
  299.         goto finish_InstallOption
  300.         endif
  301.  
  302.         ifstr(i) $($R0) == STATUS_CURRENT
  303.         else-ifstr(i) $($R0) == STATUS_NEW
  304.         set DoActualCopy = YES
  305.         else-ifstr(i) $($R0) == STATUS_USERCANCEL
  306.         Debug-Output "VIDEO.INF: User cancelled video installation"
  307.         goto finish_InstallOption
  308.         else
  309.         Debug-Output "VIDEO.INF: Error reported in DriversExist routine in SUBROUTN.INF"
  310.         goto finish_InstallOption
  311.         endif
  312.     endif
  313.  
  314.     ifstr(i) $(DoActualCopy) == YES
  315.  
  316.         shell "subroutn.inf" DoAskSourceEx $(SrcDir) $(String2)
  317.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  318.         Debug-Output "VIDEO.INF: shelling DoAskSourceEx failed"
  319.         goto finish_InstallOption
  320.         endif
  321.  
  322.         ifstr(i) $($R0) == STATUS_SUCCESSFUL
  323.         set SrcDir = $($R1)
  324.         ifstr(i) $($R2) != ""
  325.             set DrivesToFree = >($(DrivesToFree), $($R2))
  326.         endif
  327.         else
  328.         Debug-Output "VIDEO.INF: User cancelled asking source."
  329.         goto finish_InstallOption
  330.         endif
  331.  
  332.         install Install-AddCopyOption
  333.         ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  334.         Debug-Output "VIDEO.INF: Adding video files to copy list failed"
  335.         goto finish_InstallOption
  336.         endif
  337.     else
  338.         set DoCopy = NO
  339.     endif
  340.  
  341.     endif
  342.  
  343.     ifstr(i) $(DoCopy) == "YES"
  344.     read-syms ProgressCopy$($0)
  345.     install Install-DoCopyOption
  346.     ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_FAILURE"
  347.         Debug-Output "Copying files failed"
  348.         goto finish_InstallOption
  349.     else-ifstr(i) $(STF_INSTALL_OUTCOME) == "STF_USERQUIT"
  350.         set Status = STATUS_USERCANCEL
  351.         goto finish_InstallOption
  352.     endif
  353.     endif
  354.  
  355.     ifstr(i) $(DoConfig) == "YES"
  356.  
  357.     ;
  358.     ; first run a privilege check on modifying the setup node
  359.     ;
  360.  
  361.     shell "registry.inf" CheckSetupModify
  362.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  363.         goto finish_InstallOption
  364.     endif
  365.  
  366.     ifstr(i) $($R0) != STATUS_SUCCESSFUL
  367.         goto finish_InstallOption
  368.     endif
  369.  
  370.     ;
  371.     ; first make a new video entry, the entry is created automatically
  372.     ; enabled
  373.     ;
  374.  
  375.     set ServiceNode   = $(MiniportDriver)
  376.     set ServiceBinary = %SystemRoot%\System32\drivers\#(Files-DisplayMiniportDrivers, $(MiniportDriver), 2)
  377.  
  378.     set ServicesValues   = { +
  379.         {Type,           0, $(!REG_VT_DWORD),     $(Type)                  }, +
  380.         {Start,          0, $(!REG_VT_DWORD),     $(!SERVICE_SYSTEM_START) }, +
  381.         {Group,          0, $(!REG_VT_SZ),        $(Group)                 }, +
  382.         {ErrorControl,   0, $(!REG_VT_DWORD),     $(ErrorControl)          }, +
  383.         {Tag,            0, $(!REG_VT_DWORD),     $(Tag)                   }, +
  384.         {BinaryPathName, 0, $(!REG_VT_EXPAND_SZ), $(ServiceBinary)         }  +
  385.         }
  386.  
  387.     set ParametersValues = { +
  388.         {InstalledDisplayDrivers,     0, $(!REG_VT_MULTI_SZ), $(InstalledDisplays) }, +
  389.         {VgaCompatible,               0, $(!REG_VT_DWORD),    $(VgaCompatible)     }, +
  390.         {DefaultSettings.BitsPerPel,  0, $(!REG_VT_DWORD),    $(BitsPerPel)        }, +
  391.         {DefaultSettings.VRefresh,    0, $(!REG_VT_DWORD),    $(VRefresh)          }, +
  392.         {DefaultSettings.Interlaced,  0, $(!REG_VT_DWORD),    $(Interlaced)        }, +
  393.         {DefaultSettings.XResolution, 0, $(!REG_VT_DWORD),    $(XResolution)       }, +
  394.         {DefaultSettings.YResolution, 0, $(!REG_VT_DWORD),    $(YResolution)       }  +
  395.         }
  396.  
  397.     ifstr(i) $(VRefresh) != ""
  398.         set VRefreshValue = {DefaultSettings.VRefresh, 0, $(!REG_VT_DWORD), $(VRefresh)}
  399.         set ParametersValue = >($(ParametersValue), $(VRefreshValue))
  400.     endif
  401.  
  402.     ifstr(i) $(Interlaced) != ""
  403.         set InterlacedValue = {DefaultSettings.Interlaced, 0, $(!REG_VT_DWORD), $(Interlaced)}
  404.         set ParametersValue = >($(ParametersValue), $(InterlacedValue))
  405.     endif
  406.  
  407.     set DeviceValues     = {}
  408.     set EventLogValues   = { +
  409.         {EventMessageFile, 0, $(!REG_VT_EXPAND_SZ), $(EventMessageFile) }, +
  410.         {TypesSupported,   0, $(!REG_VT_DWORD),     $(TypesSupported)   }  +
  411.         }
  412.  
  413.     shell "registry.inf"  MakeServicesEntry $(ServiceNode)      +
  414.                         $(ServicesValues)   +
  415.                         $(ParametersValues) +
  416.                         $(DeviceValues)     +
  417.                         $(EventLogValues)   +
  418.                         Device0
  419.  
  420.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  421.         Debug-Output "Couldn't execute MakeServicesEntry in registry.inf"
  422.         goto finish_InstallOption
  423.     endif
  424.  
  425.     ifstr(i) $($R0) != STATUS_SUCCESSFUL
  426.         Debug-Output "MakeServicesEntry failed for video"
  427.         goto finish_InstallOption
  428.     endif
  429.  
  430.     ;
  431.     ;
  432.     ; then disable the previous video entry
  433.     ;
  434.  
  435.     ifstr(i) $(CurrentEntry) != $(MiniportDriver)
  436.         ifstr(i) $(CurrentEntry) != VGA
  437.         ifstr(i) $(CurrentEntry) != ""
  438.             shell "registry.inf" ModifyServicesEntry $(CurrentEntry) $(!SERVICE_DISABLED)
  439.  
  440.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  441.             Debug-Output "Couldn't find DisableServicesEntry in registry.inf"
  442.             goto errorconfig
  443.             endif
  444.  
  445.             ifstr(i) $($R0) != STATUS_SUCCESSFUL
  446.             Debug-Output "DisableServices entry failed"
  447.             endif
  448.         endif
  449.         endif
  450.     endif
  451.  
  452.     goto configdone
  453.  
  454. errorconfig = +
  455.     ifstr(i) $(CurrentEntry) != $(MiniportDriver)
  456.         shell "registry.inf" ModifyServicesEntry $(MiniportDriver) $(!SERVICE_DISABLED)
  457.         ifstr(i) $(CurrentEntry) != ""
  458.         shell "registry.inf" ModifyServicesEntry $(CurrentEntry) $(!SERVICE_SYSTEM_START)
  459.         endif
  460.     endif
  461.     goto finish_InstallOption
  462.  
  463. configdone = +
  464.  
  465.     endif
  466.  
  467.     set Status = STATUS_SUCCESSFUL
  468.  
  469. finish_InstallOption = +
  470.     ForListDo $(DrivesToFree)
  471.     LibraryProcedure STATUS,$(!LIBHANDLE), DeleteNetConnection $($) "TRUE"
  472.     EndForListDo
  473.  
  474.     Return $(Status)
  475.  
  476.  
  477. [Install-AddCopyOption]
  478.  
  479.     set STF_VITAL = ""
  480.     ;
  481.     ; Add the files to the copy list
  482.     ;
  483.     AddSectionKeyFileToCopyList   Files-DisplayMiniportDrivers   +
  484.                   $(MiniportDriver)              +
  485.                   $(SrcDir)                      +
  486.                   $(!STF_WINDOWSSYSPATH)\drivers
  487.  
  488.     ForListDo $(InstalledDisplays)
  489.     AddSectionKeyFileToCopyList   Files-DisplayDLLs          +
  490.                       $($)                       +
  491.                       $(SrcDir)                  +
  492.                       $(!STF_WINDOWSSYSPATH)
  493.  
  494.     EndForListDo
  495.  
  496.     exit
  497.  
  498.  
  499. [Install-DoCopyOption]
  500.  
  501.     ;
  502.     ; Copy files in the copy list
  503.     ;
  504.     CopyFilesInCopyList
  505.     exit
  506.  
  507. ;**************************************************************************
  508. ; PROGRESS GUAGE VARIABLES
  509. ;**************************************************************************
  510.  
  511. [ProgressCopyENG]
  512.     ProCaption   = "Windows NT Setup"
  513.     ProCancel    = "Cancel"
  514.     ProCancelMsg = "Windows NT is not correcly installed.  Are you sure you want "+
  515.            "to cancel copying files?"
  516.     ProCancelCap = "Setup Message"
  517.     ProText1     = "Copying:"
  518.     ProText2     = "To:"
  519.  
  520. [StringsENG]
  521.     String1 = "Display"
  522.     String2 = "Please enter the full path to the OEM Display "+
  523.           "driver files.  Then choose Continue."
  524.  
  525. ;-----------------------------------------------------------------------
  526. ; SOURCE MEDIA DESCRIPTIONS
  527. ; -------------------------
  528. ; The OEM should list all the diskette labels here.  The source media
  529. ; description is used during copy to prompt the user for a diskette
  530. ; if the source is diskettes.
  531. ;
  532. ; Use 1 = "Diskette 1 Label" , TAGFILE = disk1
  533. ;     2 = "Diskette 2 Label" , TAGFILE = disk2
  534. ;     ...
  535. ;-----------------------------------------------------------------------
  536.  
  537. ;--------------------------------------------------------------------
  538. ; THE SECTIONS BELOW SHOULD BE AUTOMATICALLY GENERATED BY THE EXCEL
  539. ; SPREAD SHEETS
  540. ;--------------------------------------------------------------------
  541.  
  542. [Source Media Descriptions]
  543.     1  = "3Dfx Interactive, Inc. Installation DISK (VIDEO)", TAGFILE = disk1
  544.  
  545. [Files-DisplayDLLs]
  546. framebuf = 1,framebuf.dll , SIZE=999
  547.  
  548. [Files-DisplayMiniportDrivers]
  549. velocity = 1, velocity.sys , SIZE=999
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570. b
  571.